package com.yuandian.customer.perception.controller;

import com.yuandian.api.customer_perception.po.BusinessDetailParams;
import com.yuandian.bpm.common.core.util.R;
import com.yuandian.customer.perception.service.IBusinessDetailService;
import com.yuandian.utils.PageDataInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 说明：业务明细controller
 * @Author yanjun
 * @Date 2021/3/18 13:15
 */
@RestController
@RequestMapping("/business/detail")
public class BusinessDetailController {

    @Autowired
    private IBusinessDetailService businessDetailService;

    /**
     * 查询业务明细列表
     * @param params 业务明细请求参数
     * @return 通用返回对象
     */
    @PostMapping("/list")
    public R<PageDataInfo> list(@RequestBody BusinessDetailParams params) {
        PageDataInfo info = businessDetailService.queryBusinessDetailList(params);
        return R.ok(info);
    }

}
